package xyz.vmcserver.wdibbs.model.dao;

import com.beust.jcommander.Parameter;
import org.apache.ibatis.annotations.Param;
import xyz.vmcserver.wdibbs.model.po.ArticleView;
import xyz.vmcserver.wdibbs.model.po.UserView;
import xyz.vmcserver.wdibbs.model.vo.User;

import java.util.List;

public interface UserMapper {

    void insertUser(User user);

//    public void insertUserRegisterInfo(String username,Long time,String register_ip,String code);

    User selectByUsernameAndPassword(User user);

    String selectSaltByUsername(String username);

    UserView selectUserByUsername(String username);

    void updateUserGroupByActivationCode(String code);

    void updateUserGroupByActivationCode(@Param("code") String code,@Param("userGroup") String userGroup);

    List<UserView> searchUserByKeyAndValuePages(@Param("value") String value , @Param("page") Integer page , @Param("sortType") String sortType, @Param("sortValue")String sortValue);
}
